package com.qiaofang.applet.service.property.repository;

import com.qiaofang.applet.service.property.domain.EstateHouseTypeFy;
import org.springframework.data.mongodb.repository.DeleteQuery;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public interface EstateHouseTypeFyRepository extends MongoRepository<EstateHouseTypeFy, String> {

    EstateHouseTypeFy findByEstateUniqueUuidAndPhotoUuidAndPropertyUniqueUuid(String estateUniqueUuid, String photoUuid, String propertyUniqueUuid);

    @DeleteQuery("{ 'estateUniqueUuid': '?0', 'photoUuid': '?1', 'propertyUniqueUuid': '?2' }")
    int deleteByEstateUniqueUuidAndPhotoUuidAndPropertyUniqueUuid(String estateUniqueUuid, String photoUuid, String propertyUniqueUuid);

    List<EstateHouseTypeFy> findByEstateUniqueUuidAndPhotoUuid(String estateUniqueUuid, String photoUuid);
}
